/*
* StepDao.java
* Created on  202015/5/1 13:32
* 版本       修改时间          作者      修改内容
* V1.0.1    202015/5/1       panzhuowen    初始版本
*
*/

package com.infitecs.eyas.step.dao;

import com.infitecs.eyas.step.modal.StepInfo;
import com.infitecs.krill.mybatis.annotation.mybatisRepository;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 类的描述信息
 *
 * @author panzhuowen
 * @version 1.0.1
 */
@mybatisRepository
public interface StepDao {

    boolean addNewStep(StepInfo stepInfo);

    int updateStepStateing(@Param("caseId") int caseId,@Param("stepId") int stepId);

    int updateStepStateFinish(@Param("caseId") int caseId,@Param("stepId") int stepId);

    int findStepIdByCaseId(@Param("caseId") int caseId);

    int findStepIdByCaseIdWithNo(@Param("caseId") int caseId);

    int checkIsGoBack(@Param("stepId") int stepId,@Param("caseId") int caseId);

    int getFinishStepId(@Param("caseId")int caseId,@Param("stepId") int stepId);

    List<StepInfo> getStepListByCaseId(String caseId);

    int updateStepFinish(StepInfo stepInfo);
}
